﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace LogSystem
{
    // LoggerFactory.cs
    public static class LoggerFactory
    {
        public static ILogger CreateLogger(string loggerType)
        {
            switch (loggerType.ToLower())
            {
                case "console":
                    return new ConsoleLogger();
                case "file":
                    return new FileLogger();
                case "db":
                    return new DBLogger();
                default:
                    throw new ArgumentException("Invalid logger type");
            }
        }
    }
}
